<!DOCTYPE html>
<html lang="zh">
<html xmlns:th="http://www.thymeleaf.org">
<head th:replace="common/header :: header(~{::title},~{::link},~{})">
    <title>临窗旋墨的博客</title>
    <link rel="icon" th:href="@{/assets/img/lcxm.ico}" type="image/ico">
    <link rel="stylesheet" th:href="@{/css/style.css}">
</head>
<body class="body">
<!--导航-->
<div th:replace="common/nav :: nav(true)"></div>

<div class="container-fluid">

    <div class="row">
        <div style="margin-top: 20px;"></div>
        <!-- 中间 start -->
        <div class="col-lg-9  col-sm-9 col-md-9">

            <div class="row">
                <!-- 最新statr -->
                <div class="col-lg-12 col-md-12 col-sm-12 ">
                    <div class="panel panel-success shadow">
                        <div class="panel-heading">
                            <h3 class="panel-title">
                                最新文章
                            </h3>
                        </div>
                        <div class="panel-body">
                            <div class="panel-body-list" th:each="item: ${model.newest}">
                                <span th:text="${#dates.format(item.createTime, 'yyyy-MM-dd')}">2020-12-12</span>

                                <a th:href="@{'/detail/' + ${item.id}}" target="_blank" th:attr="title=${item.title}"
                                   th:text="${item.title}">title</a>

                                <a th:href="@{'/topics?tid=' + ${item.topicId}}" target="_blank"><span th:text="${item.topicName}">专题</span></a>

                            </div>

                        </div>
                        <div class="panel-footer text-info text-right small"><a th:href="@{/categories}"
                                                                                target="_blank">查看更多</a></div>
                    </div>
                </div>
                <!-- 最新end -->

                <!-- 专题 start -->
                <div class="col-lg-12 col-md-12 col-sm-12" th:each="showTopic, state: ${model.showTopics}">
                    <div class="panel panel-success shadow">
                        <div class="panel-heading">
                            <h3 class="panel-title" th:text="${showTopic.name}">
                                专题名称
                            </h3>
                        </div>
                        <div class="panel-body">
                            <div class="panel-body-list" th:each="article:${showTopic.articles}">
                                <span th:text="${#dates.format(article.createTime, 'yyyy-MM-dd')}">创建时间</span>
                                <a th:href="@{'/detail/' + ${article.id}}" target="_blank"
                                   th:attr="title=${article.title}" th:text="${article.title}">文章标题</a>
                            </div>
                        </div>
                        <div class="panel-footer text-info text-right small"><a
                                th:href="@{'/topics?tid=' + ${showTopic.id}}" target="_blank">查看更多</a></div>
                    </div>
                </div>
                <!-- 专题 end -->

                <!-- TODO start -->
                <div class="col-lg-12 col-md-12 col-sm-12">
                    <div class="panel panel-success">
                        <div class="panel-heading">
                            <h3 class="panel-title">
                                TODO
                            </h3>
                        </div>
                        <div class="panel-body">
                            <div class="panel-body-list">
                                <span>20/03/08</span>
                                <a href="/spring-boot-learning-21-3-6/" target="_blank" itemprop="url">Spring Boot
                                    2.x基础教程：使用MyBatis的XML配置方式
                                    Spring Boot 2.x基础教程：使用MyBatis的XML配置方式</a>
                            </div>

                            <div class="panel-body-list">
                                <span>20/02/29</span>
                                <a href="/spring-boot-learning-21-3-5/" target="_blank" itemprop="url">Spring Boot
                                    2.x基础教程：使用MyBatis访问MySQL</a>
                            </div>
                        </div>
                        <div class="panel-footer text-info text-right small"><a>查看更多</a></div>
                    </div>
                </div>
                <!-- TODO end -->

                <!-- 功能展示start -->
                <div class="col-lg-12 col-md-12 col-sm-12">
                    <div class="panel panel-success">
                        <div class="panel-heading">
                            <h3 class="panel-title">
                                功能展示 暂无
                            </h3>
                        </div>
                        <div class="panel-body">
                            <div class="panel-body-list">
                                <span>20/03/08</span>
                                <a href="/spring-boot-learning-21-3-6/" target="_blank" itemprop="url">Spring Boot
                                    2.x基础教程：使用MyBatis的XML配置方式</a>
                            </div>

                            <div class="panel-body-list">
                                <span>20/02/29</span>
                                <a href="/spring-boot-learning-21-3-5/" target="_blank" itemprop="url">Spring Boot
                                    2.x基础教程：使用MyBatis访问MySQL</a>
                            </div>
                        </div>
                        <div class="panel-footer text-info text-right small"><a>查看更多</a></div>
                    </div>
                </div>
                <!-- 功能展示end -->
            </div>
        </div>
        <!-- 中间 end -->
        <div th:replace="common/right :: right"></div>

    </div>
</div>

<!-- 引入通用js-->
<div th:replace="common/footer :: footer"></div>

</body>
</html>